<?php
/**
 * Smarty plugin
 *
 * @package    Smarty
 * @subpackage PluginsModifier
 */

/**
 * Smarty is_session modifier plugin
 * Type:     modifier<br>
 * Name:     is_session<br>
 * Purpose:  check if a session is set
 *
 * @author Rei@king dot moe
 *
 * @param string  $name        session name
 * @return bool true for is set false for not set
 */

function smarty_modifier_is_session($name){
    return isset($_SESSION[$name]);
}